home *** CD-ROM | disk | FTP | other *** search
- rem $linesize:132
- rem $title:'Application Engineer Standard Routines'
- rem $subtitle:'Release / Add a record to the UNUSED list.'
- ' Include the COMMON values
- rem $include:'AESHARED.BAS'
-
- sub Release.Avail.Record(fl%,rlen%,rec%) static
-
- r%=rlen%-8% ' Rest of the record
-
- field #fl%,1 as stat$,2 as n.av$,2 as l.av$,1 as mj$,1 as mn$,1 as bug.fix$
- field #fl%,8 as dummy$,r% as filler$
-
- ' stat$ = Status (1 = Open / 2 = Closed)
- ' n.av$ = Next available record
- ' l.av$ = Last available record
- ' mj$ = Application Engineer Major release version
- ' mn$ = Application Engineer Minor release version
- ' bug.fix$ = Bug fix code within Minor release
-
- get #fl%,1%
-
- if mj$<>chr$(0%) or _
- mn$<>chr$(0%) or _
- bug.fix$<>"B" _
- then
- call ae.error("RAR Version mismatch error. Action 01")
- end if
-
- nav%=cvi(n.av$)
- lav%=cvi(l.av$)
-
- field #fl%,2 as pt$,r%+6% as filler$
-
- get #fl%,rec% ' Get the record to release
- lset pt$=mki$(nav%) ' Set the pointer to old next avail
- put #fl%,rec% ' Write that record back
-
- get #fl%,1% ' Read the header in again
- lset n.av$=mki$(rec%) ' Set the next available record
- put #fl%,1% ' Write the header back
-
- end sub